package database;

import java.sql.SQLException;

public class CHANGE {

	public static void change(String number, String name, String gender, String birthdate, String politics,
			String address, String telephone, String dormitory) {
		String str = "update students set number='" + number + "',gender='" + gender + "'," + "birthdate='" + birthdate
				+ "'," + "politics='" + politics + "'," + "address='" + address + "'," + "telephone='" + telephone
				+ "'," + "dormitory='" + dormitory + "' " + "where name=" + "'" + name + "';";
		try {
			System.out.println(str);
			DBUtil.exec(str);
		} catch (ClassNotFoundException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (SQLException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}

	}

}
